/**
 * UDP报文类
 */
#ifndef __PACK_UDP_H_INCLUDED__
#define __PACK_UDP_H_INCLUDED__

#include <netinet/tcp.h>
#include <netinet/udp.h>

#ifdef __cplusplus
extern "C" {
#endif

class pack_udp{

public:

	pack_udp(void* ptr);
	~pack_udp();
	uint16_t get_src();
	uint16_t get_dst();
	void set_src(uint16_t port);
	void set_dst(uint16_t port);
	uint16_t get_check();
	uint32_t get_len();
	char* get_app_layer();
	void print_buffer();

public:

	pack_udp();

	udphdr* ptr;

};

#ifdef __cplusplus
}
#endif

#endif // __PACK_UDP_H_INCLUDED__
